﻿<Window x:Class="ISRecord.View.MessageDialog"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Title="MessageDialog" 
               FlowDirection="RightToLeft"
        MinHeight="200" MinWidth="400"
        ResizeMode="NoResize" SizeToContent="WidthAndHeight"
        FontFamily="Traditional Arabic" FontSize="16" FontWeight="Bold"
        WindowStartupLocation="CenterScreen" Loaded="Window_Loaded">
    <Window.Resources>
        <Style x:Key="footerButtonStyle" TargetType="{x:Type Button}">
            <Setter Property="Width" Value="55"/>
            <Setter Property="Height" Value="55"/>
            <Setter Property="Margin" Value="0,15,0,0"/>

        </Style>
        <Style x:Key="footerPanelStyle" TargetType="{x:Type UniformGrid}">
            <Style.Resources>
                <Style TargetType="{x:Type Button}" BasedOn="{StaticResource footerButtonStyle}"/>
            </Style.Resources>
            <Setter Property="Rows" Value="1"/>
            <!--<Setter Property="HorizontalAlignment" Value="Stretch"/>-->
        </Style>
        <Image x:Key="okImage" Width="48" Height="48" Source="Images/Ok.png"/>
        <Image x:Key="cancelImage" Width="48" Height="48" Source="Images/Cancel.png"/>
    </Window.Resources>
    <DockPanel Margin="14">
        <!--Main Content-->
        <Grid DockPanel.Dock="Top">
            <Grid.RowDefinitions>
                <RowDefinition />
            </Grid.RowDefinitions>
            <Grid.ColumnDefinitions>
                <ColumnDefinition />
            </Grid.ColumnDefinitions>
            <StackPanel Grid.Column="0" Grid.Row="0">
                <TextBlock x:Name="message" Text="{Binding Path=''}" Grid.Row="0" Grid.Column="0" />
            </StackPanel>
        </Grid>
        <!--Footer-->
        <UniformGrid DockPanel.Dock="Bottom" Style="{StaticResource footerPanelStyle}">
            <Button x:Name="btnOk" Content="{StaticResource okImage}" 
                    ToolTip="موافق" IsDefault="True" Click="BtnOk_Click" />
            <Button x:Name="btnCancel" Content="{StaticResource cancelImage}"
                    ToolTip="إلغاء" IsCancel="True" Click="BtnCancel_Click" />
        </UniformGrid>
    </DockPanel>
</Window>
